# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.ToolResults.V1beta3.Model.AndroidTest do
  @moduledoc """
  An Android mobile test specification.

  ## Attributes

  *   `androidAppInfo` (*type:* `GoogleApi.ToolResults.V1beta3.Model.AndroidAppInfo.t`, *default:* `nil`) - Information about the application under test.
  *   `androidInstrumentationTest` (*type:* `GoogleApi.ToolResults.V1beta3.Model.AndroidInstrumentationTest.t`, *default:* `nil`) - An Android instrumentation test.
  *   `androidRoboTest` (*type:* `GoogleApi.ToolResults.V1beta3.Model.AndroidRoboTest.t`, *default:* `nil`) - An Android robo test.
  *   `androidTestLoop` (*type:* `GoogleApi.ToolResults.V1beta3.Model.AndroidTestLoop.t`, *default:* `nil`) - An Android test loop.
  *   `testTimeout` (*type:* `GoogleApi.ToolResults.V1beta3.Model.Duration.t`, *default:* `nil`) - Max time a test is allowed to run before it is automatically cancelled.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :androidAppInfo => GoogleApi.ToolResults.V1beta3.Model.AndroidAppInfo.t() | nil,
          :androidInstrumentationTest =>
            GoogleApi.ToolResults.V1beta3.Model.AndroidInstrumentationTest.t() | nil,
          :androidRoboTest => GoogleApi.ToolResults.V1beta3.Model.AndroidRoboTest.t() | nil,
          :androidTestLoop => GoogleApi.ToolResults.V1beta3.Model.AndroidTestLoop.t() | nil,
          :testTimeout => GoogleApi.ToolResults.V1beta3.Model.Duration.t() | nil
        }

  field(:androidAppInfo, as: GoogleApi.ToolResults.V1beta3.Model.AndroidAppInfo)

  field(:androidInstrumentationTest,
    as: GoogleApi.ToolResults.V1beta3.Model.AndroidInstrumentationTest
  )

  field(:androidRoboTest, as: GoogleApi.ToolResults.V1beta3.Model.AndroidRoboTest)
  field(:androidTestLoop, as: GoogleApi.ToolResults.V1beta3.Model.AndroidTestLoop)
  field(:testTimeout, as: GoogleApi.ToolResults.V1beta3.Model.Duration)
end

defimpl Poison.Decoder, for: GoogleApi.ToolResults.V1beta3.Model.AndroidTest do
  def decode(value, options) do
    GoogleApi.ToolResults.V1beta3.Model.AndroidTest.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.ToolResults.V1beta3.Model.AndroidTest do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
